package com.cy.pj.module.pojo;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

public class RequestParameter {
    public RequestParameter (){
        System.out.println("。。。");
    }

    private String name;
    //当强求pojo对象请求参数是，@DateTimeFormat用于接受请求参数中指定格式的日期参数
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date startDate;

    @Override
    public String toString() {
        return "RequestParameter{" +
                "name='" + name + '\'' +
                ", startDate=" + startDate +
                '}';
    }

    public Date getStartDate() {
        return startDate;
    }

    //@DateTimeFormat("yyyy-MM-dd")
    public void setStartDate(Date startDate) {
        this.startDate = startDate;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

}
